package com.zd.service.lmpl;/**
 * @Description: DeliveryServicelmpl
 * @Author:pioneer
 * @Date: 2021-07-06
 * @Version:v1.0
 */

import com.zd.mapper.DeliveryMapper;
import com.zd.service.lnter.DeliveryServicelnter;
import com.zzg.entity.Delivery;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @Description: DeliveryServicelmpl
 * @Author:pioneer
 * @Date: 2021-07-06
 * @Version:v1.0
 */
@Service
public class DeliveryServicelmpl implements DeliveryServicelnter {
    @Autowired
    public DeliveryMapper deliveryMapper;
    /**
     * 根据运单id修改派送信息
     *
     * @param shipping     运单管理id
     * @param billingtime  开单时间
     * @param billingclerk 派送员
     * @return 返回数值判断是否成功
     */
    @Override
    public int updateDelivery(String shipping, String billingtime, String billingclerk) {
        return deliveryMapper.updateDelivery (shipping,billingtime,billingclerk);
    }

    /**
     * 根据派送单号查询派送
     *
     * @param deliverynumber 派送单号
     * @return 外包派送对象
     */
    @Override
    public Delivery getDeliveryByid(String deliverynumber) {
        return deliveryMapper.getDeliveryByid (deliverynumber);
    }

    /**
     * 根据派送单号修改派送信息
     *
     * @param deliverynumber 派送单号
     * @param deliverydate   派送时间
     * @param deliveryfee    派送费用
     * @param operator       操作员
     * @return 返回数值判断是否修改成功
     */
    @Override
    public int getupdateDelivery(String deliverynumber, String deliverydate, int deliveryfee, String operator) {
        return deliveryMapper.getupdateDelivery (deliverynumber,deliverydate,deliveryfee,operator);
    }
}
